use "${datadir}\HTB_main", replace

replace htb_dummy = !htb_dummy // to have the right order of the labels

label define htb_dummy 0 "EL" 1 "No EL"
label val htb_dummy htb_dummy

hist dealtype if ratetype == 1 & dealtype < 99, disc ///
	by(htb_dummy, note("") graphr(color(white))) ${graphoption} yti("Fraction of mortgages") ///
	xti("Length of the initial period with a discounted rate (years)") 
	
graph export "${figuredir}\length_incentive.pdf", as(pdf) replace
